home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / std / c++ / 222 < prev    next >
Encoding:
Internet Message Format  |  1996-08-06  |  2.1 KB

  1. Path: fido.asd.sgi.com!austern
  2. From: claus@faerber.muc.de (Claus Faerber)
  3. Newsgroups: comp.std.c++
  4. Subject: Re: Are all Windows programs ill-formed?
  5. Date: 01 Feb 1996 10:14:40 PST
  6. Organization: -
  7. Approved: austern@isolde.mti.sgi.com
  8. Message-ID: <61uFCRS3cDB@faerber.muc.de>
  9. NNTP-Posting-Host: isolde.mti.sgi.com
  10. X-Original-Date: Wed, 31 Jan 1996 17:12:00 +0100
  11. In-Reply-To: <AE5J83na99@qsar.chem.msu.su>
  12. X-Mailer: CrossPoint v3.1 R/B17071
  13. X-Auth: PGPMoose V1.1 PGP comp.std.c++
  14.     iQBVAwUBMREDLEy4NqrwXLNJAQF6YAH/Qt1M/XHue5gmK0jvapjZP0zVmC2Hx7EI
  15.     9LKLyOT2P1WBWUkyJvl21qI9ct/BVEdrMCSEXmSuGNhc6IICV9LVzg==
  16.     =xWLz
  17. Originator: austern@isolde.mti.sgi.com
  18.  
  19. Eugene Radchenko <eugene@qsar.chem.msu.su> wrote about
  20. Are all Windows programs ill-formed?
  21. in article <AE5J83na99@qsar.chem.msu.su> of 29 Jan 96:
  22. > Hi!
  23. > I have just realized that something is grossly overlooked in C++ standard.
  24. > It requires every program to have the main() function (which implementation
  25. > is not allowed to supply) with parameters (void) or (int argc, int*argv[]).
  26. > However, Windows programs have another convention: prrogram must contain
  27. > the function
  28. >   int WinMain(HINSTANCE curInst, HINSTANCE prevInst, LPSTR cmdline, int
  29. > cmdShow) Some of this is of course quirks or even outright ignored in Win32
  30. > (prevInst), but the full non-parsed command line could be useful sometimes,
  31. > and not all implementations provide the function retrieving it. And anyway
  32. > this is definitely not a main() from the specs. Maybe the requirements on
  33. > the main() should be relaxed somehow?
  34.  
  35. The actual main() procedure is part of the C++ Windows run- 
  36. time library and it's this function which calls Win/LibMain.
  37.  
  38. Claus
  39.  
  40. ------------------------------------------------------------------------
  41. Claus Andre Faerber - claus@faerber.muc.de - http://www.muc.de/~cfaerber
  42. ------------------------------------------------------------------------
  43. ---
  44. [ comp.std.c++ is moderated.  Submission address: std-c++@ncar.ucar.edu.
  45.   Contact address: std-c++-request@ncar.ucar.edu.  The moderation policy is
  46.   in http://reality.sgi.com/employees/austern_mti/std-c++/policy.html. ]
  47.